home *** CD-ROM | disk | FTP | other *** search
/ Columbia Kermit / kermit.zip / newsgroups / misc.20041116-20060924 / 000136_slash_dev_slas…_2000@yahoo.com_Wed Aug 17 10:18:01 2005.msg < prev    next >
Internet Message Format  |  2020-01-01  |  3KB

  1. Path: newsmaster.cc.columbia.edu!panix!news.maxwell.syr.edu!postnews.google.com!f14g2000cwb.googlegroups.com!not-for-mail
  2. From: "Mark Sapiro" <slash_dev_slash_null_2000@yahoo.com>
  3. Newsgroups: comp.protocols.kermit.misc
  4. Subject: Re: Brace Style Affects Variable Expansion by ECHO
  5. Date: 16 Aug 2005 12:10:55 -0700
  6. Organization: http://groups.google.com
  7. Lines: 53
  8. Message-ID: <1124219455.123578.246130@f14g2000cwb.googlegroups.com>
  9. References: <1123635685.649422.152630@z14g2000cwz.googlegroups.com>
  10. NNTP-Posting-Host: 209.182.169.133
  11. Mime-Version: 1.0
  12. Content-Type: text/plain; charset="iso-8859-1"
  13. X-Trace: posting.google.com 1124219460 25608 127.0.0.1 (16 Aug 2005 19:11:00 GMT)
  14. X-Complaints-To: groups-abuse@google.com
  15. NNTP-Posting-Date: Tue, 16 Aug 2005 19:11:00 +0000 (UTC)
  16. User-Agent: G2/0.2
  17. Complaints-To: groups-abuse@google.com
  18. Injection-Info: f14g2000cwb.googlegroups.com; posting-host=209.182.169.133;
  19.    posting-account=iQNWIg0AAAAD2fStXNC9nwGlPdSqjWrI
  20. Xref: newsmaster.cc.columbia.edu comp.protocols.kermit.misc:15377
  21.  
  22. Allen wrote:
  23. > While experimenting with different brace styles, I ran across a
  24. > situation in which variables used within an ECHO string were not being
  25. > expanded.
  26. >
  27. > The following test script,
  28. > .\%j = 3
  29. > for \%i 0 5 1 {
  30. >   IF < \%i \%j { ECHO \%i is less than \%j on \v(ndate)}
  31. >   ELSE { ECHO \%i is not less than \%j on \v(ndate)}
  32. > }
  33. >
  34. > produces this output:
  35. > [C:\temp\] K-95> take test1.ksc
  36. > 0 is less than 3 on 20050809
  37. > 1 is less than 3 on 20050809
  38. > 2 is less than 3 on 20050809
  39. > \%i is not less than \%j on \v(ndate)
  40. > \%i is not less than \%j on \v(ndate)
  41. > \%i is not less than \%j on \v(ndate)
  42. >
  43. > However if I just remove the braces in the ELSE statement,
  44. > .\%j = 3
  45. > for \%i 0 5 1 {
  46. >   IF < \%i \%j { ECHO \%i is less than \%j on \v(ndate)}
  47. >   ELSE ECHO \%i is not less than \%j on \v(ndate)
  48. > }
  49. >
  50. > the script behaves as one would expect:
  51. > [C:\temp\] K-95> take test2.ksc
  52. > 0 is less than 3 on 20050809
  53. > 1 is less than 3 on 20050809
  54. > 2 is less than 3 on 20050809
  55. > 3 is not less than 3 on 20050809
  56. > 4 is not less than 3 on 20050809
  57. > 5 is not less than 3 on 20050809
  58.  
  59.  
  60. This is one manifestation of a larger problem that has existed for
  61. quite some time. The problem was concidentally just fixed (on Aug 11)
  62. in the C-Kermit source as part of another fix. See
  63. http://www.columbia.edu/kermit/ckdaily.html
  64.  
  65.  
  66. > I'm running Kermit 95 2.1.3, 1 Jan 2003 under Windows XP SP 2.
  67.  
  68. The fix has not yet made it into a Kermit 95 release. When a K-95
  69. update is released, the fix will be there too.
  70.  
  71. --
  72. Mark Sapiro msapiro at value net      The highway is for gamblers,
  73. San Francisco Bay Area, California    better use your sense - B. Dylan
  74.